package messages;


/**
 * InvalidInvitationReceivedMessage
 * 
 * Message sent by the server in reply to an invalid invitation.
 * An invitation will be invalid if the destiny player does not
 * exist or is offline.
 */
public class InvalidInvitationReceivedMessage extends Message {

	public enum ErrorCode { UnknownUser, UnknownGame }
	
	public InvalidInvitationReceivedMessage(InvitationMessage originalMessage, ErrorCode errorCode) {
		super();
		
		this.errorCode = errorCode;
		this.originalMessage = originalMessage;
	}
			
	
	public ErrorCode getErrorCode() {
		return this.errorCode;
	}


	public InvitationMessage getOriginalMessage() {
		return this.originalMessage;
	}
	

	private ErrorCode errorCode;			// The error code that explains why the invitation failed
	private InvitationMessage originalMessage;	// The original message sent by the player

	private static final long serialVersionUID = 1L;
}
